<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');

class Site extends CI_Controller {
	public function __construct()
	{
		parent::__construct();
		$this->load->model('Category_model','category');
	}
	/**
	 * Index Page for this controller.
	 *
	 * Maps to the following URL
	 * 		http://example.com/index.php/welcome
	 *	- or -  
	 * 		http://example.com/index.php/welcome/index
	 *	- or -
	 * Since this controller is set as the default controller in 
	 * config/routes.php, it's displayed at http://example.com/
	 *
	 * So any other public methods not prefixed with an underscore will
	 * map to /index.php/welcome/<method_name>
	 * @see http://codeigniter.com/user_guide/general/urls.html
	 */
	public function index()
	{
		$this->load->view('site/index',array('title'=>'iMore 艾木'));
	}
	
	public function login()
	{
		
		$user = $this->User_model->login('luochong1987@gmail.com','123456');
		redirect(urldecode($_GET['url']));
	}
	
	public function logout()
	{
		$this->User_model->logout();
		redirect(site_url());
	}
	
	public function postage()
	{
		$this->load->view('site/postage',array('title'=>'全场包邮 - 艾木 iMore.cc'));
	}
	
	public function credit()
	{
		$this->load->view('site/credit',array('title'=>'信誉保证 - 艾木 iMore.cc'));
	}
	
	public function payment()
	{
		$this->load->view('site/payment',array('title'=>'支付保障 - 艾木 iMore.cc'));
	}
	
	public function points()
	{
		$this->load->view('site/points',array('title'=>'积分反馈 - 艾木 iMore.cc'));
	}
	
	public function wiki()
	{
		$this->load->view('site/wiki',array('title'=>'贴膜百科 - 艾木 iMore.cc'));
	}
	
	public function sign()
	{
		$this->load->view('site/sign',array('title'=>'签收须知 - 艾木 iMore.cc'));
	}
}

/* End of file site.php */
/* Location: ./application/controllers/site.php */